import request from '../utils/request'

export function list(params) {
  return request({
    url: '/admin/askfor/list',
    method: 'get',
    params: params
  })
}
export function find(id) {
  return request({
    url: '/admin/askfor/find/' + id,
    method: 'get'
  })
}

export function confirm(ids) {
  return request({
    url: '/admin/askfor/confirm/' + ids,
    method: 'post'
  })
}

export function refunds(ids) {
  return request({
    url: '/admin/askfor/refund/' + ids,
    method: 'post'
  })
}
export function cancel(ids) {
  return request({
    url: '/admin/askfor/cancel/' + ids,
    method: 'post'
  })
}

export function shipping(ids, data) {
  return request({
    url: '/admin/askfor/shipping/' + ids,
    method: 'post',
    data: data
  })
}

export function update(data, params) {
  return request({
    url: '/admin/askfor/update',
    method: 'post',
    data: data,
    params: params
  })
}
export function received(id, params) {
  return request({
    url: '/admin/askfor/received/' + id,
    method: 'post',
    params: params
  })
}

export function receivedAndAudit(id, params) {
  return request({
    url: '/admin/askfor/receivedAndAudit/' + id,
    method: 'post',
    params: params
  })
}

export function summary() {
    return request({
        url: '/admin/askfor/summary',
        method: 'post'
    })
}


